package com.hup.sb;

import com.hup.sb.view.MainWindow;
import com.hup.utils.commons.exception.AppExceptionHandler;
import com.hup.utils.commons.exception.ErrInfo;
import com.hup.utils.commons.start.AppInfo;
import com.hup.utils.commons.start.DialogHelper;
import com.hup.utils.commons.start.LookThemeUtil;

/**
 * @author hugan
 * @date 2022/2/27
 */
@AppInfo(chName = "屏幕亮度调节器")
public class ScreenBrightnessor {

    public static void main(String[] args) {
        LookThemeUtil.initNormal(null);

        try {
            MainWindow.startUp();
        } catch (Throwable e) {
            ErrInfo errInfo = AppExceptionHandler.handle("启动错误:\n", e);
            DialogHelper.confirm(errInfo.getErrMsg())
                    .title(DialogHelper.ERROR)
                    .onTop(true)
                    .show();
            System.exit(0);
        }
    }

}
